<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<title>详情</title>
		<style type="text/css">
			html, body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, code, form, fieldset, legend, input, textarea, p, blockquote, q, th, td, caption, article, aside, figure, figcaption, footer, header, hgroup, nav, section, audio, video {
			    margin: 0;
			    padding: 0;
			}
		body{
			text-align: center;
			background: #fff;
		}
		nav{
			margin: 0 auto;
			width: 1196px;
			height: 512px;
			position: relative;
			border: 1px solid #dcdcdc;
		}
		#pic{
			float: left;
			width: 400px;
			height: 497px;
			overflow: hidden;
		}
		#big{
			margin-top: 10px;
			height: 350px;
			width: 350px;
		}
		#pic ul{
			
			margin-top: 10px;
			margin-left:42px ;
			width: 400px;
			background-color: aquamarine;
		}
		li{
			float: left;
			list-style: none;
			width: 44px;
			height: 44px;
			margin: 4px;
		}
		.active{
			border: 1px solid #DCDCDC;
		}
		li img{
			vertical-align: middle;
			margin-top: 2px;
			width: 40px;
			height: 40px;
			display: block;
			border: 0;
		}
		/* 选项卡结束 */
		.shoucang {
			position: absolute;
			background-color: #7FFFD4;
			top: 500px;
		}
		.shoucang img{
			width: 50px;
			height: 17px;
			position: absolute;
			top: -50px;
			left: 237px;
			/* margin-top: 20px;
			padding-left: 20px; */
		}
		.scm{
			margin-left:65px ;
			
		}
		/* 右 */
		#right{
			float: left;
		}
		#right h1{
			text-indent: -30px;
			padding-top:10px ;
			font-size: 16px;
			    line-height: 16px;
				color: #6B6B6B;
		}
		#right p{
			color: #6B6B6B;
			padding: 5px 0;
		}
		#right h2{
			text-indent: -160px;
			color: #7F5B42;
			font-size: 24px;
		}
		#right .s1{
			text-indent:-150px ;
			padding: 1px;
			font-size: 12px;
			color: #FFFFFF;
			background-color: #7F5B42 ;
		}
		#right .s2{
			font-size: 10px;
			color: red;
		}
		#right .s3{
			
			padding: 1px;
			font-size: 12px;
			color: #FFFFFF;
			background-color: #B1544F ;
		}
		#right .s4{
			margin-left:20px ;
			background-color: #6B6B6B;
			color: #DCDCDC;
		}
		/* 灰 */
		#hui{
			position: absolute;
			top: 140px;
			left: 400px;
			width: 600px;
			height: 100px;
			background: #F6F5F3;
		}
		#hui p{
			color: #B1544F;
			font-size: 18px;
		}
		#hui .sone{
			padding: 130px;
		}
		#hui .stwo{
			padding: 98px;
		}
		#hui .p2{
			float: left;
			margin-top: 15px;
		}
		.p3{
			width: 500px;
			height: 105px;
			border-bottom:1px solid antiquewhite ;
		}
		.pb4{
			margin-top:20px ;
			float: left;
			color: #DCDCDC;
			padding: 10px;
			background: red;
		}
		/* 巨 */
		#ju{
			margin: 0 auto;
			border:1px solid #dcdcdc;
			width: 1196px;
		}
		</style>
	</head>
	<body>
		<nav>
			<div id="pic">
				<img id="big" src="./img/1.jpg" >
				<ul>
					<li class="active"><img src="img/1.jpg" ></li>
					<li><img src="img/2.jpg" ></li>
					<li><img src="img/3.jpg" ></li>
					<li><img src="img/4.jpg" ></li>
					<li><img src="img/5.jpg" ></li>
					<li><img src="img/6.jpg" ></li>
				</ul>
			</div>
			<!-- 选项卡结束 -->
				<div class="shoucang">
				<img  class="scm" src="img/shoucang.png" >
				<img src="img/fenxiang.png" >
				</div>
		
		<!-- 右	 -->
		<div id="right">
			
			<h1>DAPU紫外线超声波清洗器</h1>
			<p>商品编码： AE0H0200251100</p>
			<h2>￥199</h2>
			
			<span class="s1">会员价</span>
			<span class="s2">￥189 如何成为会员？</span>
			<br>
			<span class="s3">促销</span>
			<span class="s4">满88包邮</span>
		</div>
		<!-- 灰 -->
		<div id="hui">
			<p>
				<span class="sone">5</span>
				<span class="sone">0</span>
			</p>
			<p>
				<span class="stwo">销量(月)</span>
				<span class="stwo">用户评论数</span>
			</p>	
			<p class="p2">
			<span>颜色</span>	
			<span><button type="button">深色</button></span>	
			<span><button type="button">浅色</button></span>	
				
				
			</p>
			<p class="p3"></p>
			<p class="p4"><button class="pb4" type="button">加入购物车</button></p>
		</div>
		
		
		</nav>
		
		
		
		<!-- 巨 -->
		<div id="ju">
			<img src="img/da1.jpg" >
			<img src="img/da2.jpg" >
			<img src="img/da3.jpg" >
			<img src="img/da4.jpg" >
			<img src="img/da5.jpg" >
			<img src="img/da6.jpg" >
			<img src="img/da7.jpg" >
			<img src="img/da8.jpg" >
			<img src="img/da9.jpg" >
			<img src="img/da10.jpg" >
			<img src="img/da11.jpg" >
		</div>
	</body>
	<script type="text/javascript">
		var bg=document.getElementById('big')
		var nav=document.querySelector('nav')
		var lis=nav.querySelectorAll('li');
		//绑定
		for(let i=0;i<lis.length;i++){
			lis[i].onmouseover=function(){
				for(let i=0;i<lis.length;i++){
					lis[i].className='';
				}
				this.className='active';
				
				bg.src='img/'+[i+1]+'.jpg'
			}
		}
		// 选项卡结束
		
	</script>
</html>
